package com.demo.service.impl;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.demo.dao.OpeningReportDAO;
import com.demo.model.OpeningReport;
import com.demo.service.OpeningReportService;

@Service
public class OpeningReportServiceImpl implements OpeningReportService{

	@Autowired
	private OpeningReportDAO openingReportDAO;
	
	public int deleteByPrimaryKey(Integer id) {
		int i = openingReportDAO.deleteByPrimaryKey(id);
		return i;
	}

	public int insert(OpeningReport record) {
		return 0;
	}

	public int insertSelective(OpeningReport record) {
		return 0;
	}

	public OpeningReport selectByPrimaryKey(Integer id) {
		return null;
	}

	public int updateByPrimaryKeySelective(OpeningReport record) {
		return 0;
	}

	public int updateByPrimaryKeyWithBLOBs(OpeningReport record) {
		return 0;
	}

	public int updateByPrimaryKey(OpeningReport record) {
		return 0;
	}

	public List<OpeningReport> selectAll() {
		List<OpeningReport> listopeningreport = openingReportDAO.selectAll();
		return listopeningreport;
	}

	public List<OpeningReport> selectLike(String title,String state) {
		List<OpeningReport> likeopening = openingReportDAO.selectLike(title,state);
		return likeopening;
	}

	public void deleteBatch(String[] ids) {
		Map<String,Object> map = new HashMap<String,Object>();
		map.put("ids", ids);
		openingReportDAO.deleteBatch(map);
	}

}
